import { defineStore } from 'pinia'

export const userorderStore = defineStore({
  id: 'order', // id必填，且需要唯一
  state: () => {
    return {
     		orderNumber:'',
				orderList:[],
    }
  },
  // actions 用来修改 state
  actions: {
    initOrder(order){
			this.orderNumber = order
		},
		getOrderList(list){
			this.orderList = list
		}
  },
	// persist: {
	//   enabled: true,
	//   strategies: [
	//     {
	// 			key:'user',
	//       storage: localStorage,
	//       paths: ['loginStatus', 'token','userInfo']
	//     }
	//   ]
	// }
})
